package com.example.signtime.modules.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@TableName("sign_time")
@Data
public class SignTime {
    @TableId(type = IdType.AUTO)
    private Integer id;
    @ApiModelProperty("用户id")
    @TableField("user_id")
    private Integer userId;
    @ApiModelProperty("签到时间")
    @TableField("sign_in_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date signInTime;
    @ApiModelProperty("签退时间")
    @TableField("sign_out_time")
    private Date signOutTime;
    @ApiModelProperty("时辰，早晨0，下午1，晚上2 凌晨3")
    private Integer periods;
}
